import unittest

from Unittest.TestCase2 import testcase2

# 2.实例化加载对象并加载用例,-->得到套件对象
# suite = unittest.TestLoader().discover('用例所在的目录', '用例代码文件名*.py')
# suite = unittest.TestLoader().discover('.', pattern='TestC*.py')
suite2 = unittest.TestLoader().discover('case', pattern='test_case*.py')

# 3.实例化执行对象并执行
# runner = unittest.TextTestRunner()
# runner.run(suite)
unittest.TextTestRunner().run(suite2)
